Heat equation derivation